package van.planifolia.factory.simplefactory;

/**
 * Created by Intellij IDEA<br>
 *
 * @author Planifolia.Van
 * @version 1.0
 * @date 2022/11/8 17:02
 */
public class NoteBookFactory {
    public static NoteBook getBean(NoteType type) throws InstantiationException, IllegalAccessException {
        // 我们只要根据传递过来的反射类型创建对象即可
        return (NoteBook) type.value.newInstance();
    }
}
